package com.gzc.pm.dao;

import com.gzc.pm.bean.AlarmRuleBean;

import cn.skyclass.ibatis.IBatisDao;
import cn.skyclass.net.OperationResult;

public class AlarmRuleDao {

	private IBatisDao dao = new IBatisDao();
	
	public AlarmRuleBean getByUserId(String userId){
		return (AlarmRuleBean) dao.getFirstObject("AlarmRule.getByUserId", userId);
	}
	
	public OperationResult updateByUserId(AlarmRuleBean bean){
		return dao.executeUpdate("AlarmRule.updateByUserId", bean);
	}
	
	public OperationResult insert(AlarmRuleBean bean){
		return dao.executeInsert("AlarmRule.insert", bean);
	}
}
